<template>
  <div id="app">
    <router-view></router-view>
  </div>
</template>

<script>
export default {
  name: "App",
  data(){
    return{
      
    }
  },
  mounted(){
    //页面刷新回到顶部
     window.addEventListener("beforeunload", (e) => {
      window.scroll(0, 0);
    });
  },
  beforeCreate () {
    this.$nextTick(()=>{
      document.body.setAttribute('style', 'background:#F0F2F5')
    })
  },
  //实例销毁之前钩子--移除body 标签的属性style
  beforeDestroy () {
    document.body.removeAttribute('style')
  }
};
</script>

<style>
    @import url("./config/iconfont/iconfont.css");
* {
  padding: 0;
  margin: 0;
  font-style: normal;
}
page{
    background-color: #161622;
    }
</style>
